﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MultiResolutioning.Interfaces;
using Microsoft.DirectX;

namespace MultiResolutioning.Structures
{
	/// <summary>
	/// Klasa reprezentuje koszt laczenia przez kolapsacje.
	/// </summary>
	public class CollapseCost: ICostable
	{
		private float cost;
		private Vertex toVertex;

		/// <summary>
		/// Inicjalizuje obiekt.
		/// </summary>
		public CollapseCost()
		{
			this.cost = 0;
			this.toVertex = null;
		}

		/// <summary>
		/// Inicjalizuje obiekt.
		/// </summary>
		/// <param name="cost">Koszt.</param>
		/// <param name="vertex">Wierzcholek docelowy.</param>
		public CollapseCost(float cost, Vertex vertex)
		{
			this.cost = cost;
			this.toVertex = vertex;
		}

		/// <summary>
		/// Ustawia lub zwraca koszt.
		/// </summary>
		/// <value>
		/// The cost.
		/// </value>
		public float Cost
		{
			get { return this.cost; }
			set { this.cost = value; }
		}

		/// <summary>
		/// Ustawia lub zwraca cel.
		/// </summary>
		/// <value>
		/// Cel.
		/// </value>
		public Vertex Target
		{
			get { return this.toVertex; }
			set { this.toVertex = value; }
		}

		/// <summary>
		/// Zawsze zwraca wyjatek.
		/// </summary>
		/// <exception cref="System.NotImplementedException"></exception>
		public Vector3 NewPosition
		{
			get { throw new NotImplementedException(); }
			set { throw new NotImplementedException(); }
		}
	}
}
